package srzy.module

import srzy.common.ShellExecute
import srzy.common.Config
import srzy.dao.DBUtil

object CaseInit extends AbsCaseDeal with srzy.common.Logging {

  val sqlList = Config.getValue("root", "config", "PresetDBInitSQL").split(";").toList
  val inMemorySource = DBUtil("InMemorySource")

  def deal = {
    logger.debug("db init")
    inMemorySource.executeUpdate(sqlList)
    logger.debug("shell init")
    new ShellExecute {
      val shell = getCaseInfo.initShell
    }.executeNoOut
  }
}
